<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <meta name="robots" content="noodp" />
        <meta http-equiv="X-UA-Compatible" content="IE=edge, chrome=1">
        <title>主题文档 - 基本概念 - Lucklyの博客 - 在阅读中遇见自己</title><meta name="Description" content="探索 Hugo - LoveIt 主题的全部内容和背后的核心概念."><meta property="og:title" content="主题文档 - 基本概念" />
<meta property="og:description" content="探索 Hugo - LoveIt 主题的全部内容和背后的核心概念." />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://luckly.work/posts/theme-documentation-basics/" />
<meta property="og:image" content="https://luckly.work/posts/theme-documentation-basics/featured-image.jpg"/>
<meta property="article:published_time" content="2020-03-06T21:40:32+08:00" />
<meta property="article:modified_time" content="2020-03-06T21:40:32+08:00" />
<meta name="twitter:card" content="summary_large_image"/>
<meta name="twitter:image" content="https://luckly.work/posts/theme-documentation-basics/featured-image.jpg"/>
<meta name="twitter:title" content="主题文档 - 基本概念"/>
<meta name="twitter:description" content="探索 Hugo - LoveIt 主题的全部内容和背后的核心概念."/>
<meta name="application-name" content="Lucklyの博客 - 在阅读中遇见自己">
<meta name="apple-mobile-web-app-title" content="Lucklyの博客 - 在阅读中遇见自己"><link rel="shortcut icon" type="image/x-icon" href="/favicon.ico" />
        <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
        <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"><link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"><link rel="manifest" href="/site.webmanifest"><link rel="canonical" href="https://luckly.work/posts/theme-documentation-basics/" /><link rel="prev" href="https://luckly.work/posts/theme-documentation-content/" /><link rel="stylesheet" href="/lib/normalize/normalize.min.css"><link rel="stylesheet" href="/css/style.min.css"><link rel="stylesheet" href="/lib/fontawesome-free/all.min.css"><link rel="stylesheet" href="/lib/animate/animate.min.css"><script type="application/ld+json">
    {
        "@context": "http://schema.org",
        "@type": "BlogPosting",
        "headline": "主题文档 - 基本概念",
        "inLanguage": "en",
        "mainEntityOfPage": {
            "@type": "WebPage",
            "@id": "https:\/\/luckly.work\/posts\/theme-documentation-basics\/"
        },"image": [{
                            "@type": "ImageObject",
                            "url": "https:\/\/luckly.work\/posts\/theme-documentation-basics\/featured-image.jpg",
                            "width":  1600 ,
                            "height":  840 
                        }],"genre": "posts","keywords": "installation, configuration","wordcount":  6434 ,
        "url": "https:\/\/luckly.work\/posts\/theme-documentation-basics\/","datePublished": "2020-03-06T21:40:32+08:00","dateModified": "2020-03-06T21:40:32+08:00","publisher": {
            "@type": "Organization",
            "name": "Dillon"},"author": {
                "@type": "Person",
                "name": "Dillon"
            },"description": "探索 Hugo - LoveIt 主题的全部内容和背后的核心概念."
    }
    </script></head>
    <body header-desktop="" header-mobile=""><script type="text/javascript">(window.localStorage && localStorage.getItem('theme') ? localStorage.getItem('theme') === 'dark' : ('' === 'auto' ? window.matchMedia('(prefers-color-scheme: dark)').matches : '' === 'dark')) && document.body.setAttribute('theme', 'dark');</script>

        <div id="mask"></div><div class="wrapper"><header class="desktop" id="header-desktop">
    <div class="header-wrapper">
        <div class="header-title">
            <a href="/" title="Lucklyの博客 - 在阅读中遇见自己">Lucklyの博客 - 在阅读中遇见自己</a>
        </div>
        <div class="menu">
            <div class="menu-inner"><a class="menu-item" href="/"> 首页 </a><a class="menu-item" href="/post/"> 归档 </a><a class="menu-item" href="/categories/"> 分类 </a><a class="menu-item" href="/tags/"> 标签 </a><a class="menu-item" href="/about/"> 关于我 </a><a class="menu-item" href="/friend/" title="友链"> 友链 </a><a class="menu-item" href="https://github.com/ITmxs/" rel="noopener noreffer" target="_blank"> 阅读清单 </a><span class="menu-item delimiter"></span><a href="javascript:void(0);" class="menu-item theme-switch" title="切换主题">
                    <i class="fas fa-adjust fa-fw"></i>
                </a>
            </div>
        </div>
    </div>
</header><header class="mobile" id="header-mobile">
    <div class="header-container">
        <div class="header-wrapper">
            <div class="header-title">
                <a href="/" title="Lucklyの博客 - 在阅读中遇见自己">Lucklyの博客 - 在阅读中遇见自己</a>
            </div>
            <div class="menu-toggle" id="menu-toggle-mobile">
                <span></span><span></span><span></span>
            </div>
        </div>
        <div class="menu" id="menu-mobile"><a class="menu-item" href="/" title="">首页</a><a class="menu-item" href="/post/" title="">归档</a><a class="menu-item" href="/categories/" title="">分类</a><a class="menu-item" href="/tags/" title="">标签</a><a class="menu-item" href="/about/" title="">关于我</a><a class="menu-item" href="/friend/" title="友链">友链</a><a class="menu-item" href="https://github.com/ITmxs/" title="" rel="noopener noreffer" target="_blank">阅读清单</a><a href="javascript:void(0);" class="menu-item theme-switch" title="切换主题">
                <i class="fas fa-adjust fa-fw"></i>
            </a></div>
    </div>
</header>
<div class="search-dropdown desktop">
    <div id="search-dropdown-desktop"></div>
</div>
<div class="search-dropdown mobile">
    <div id="search-dropdown-mobile"></div>
</div>
<main class="main">
                <div class="container"><div class="toc" id="toc-auto">
            <h2 class="toc-title">目录</h2>
            <div class="toc-content always-active" id="toc-content-auto"></div>
        </div><article class="page single"><h1 class="single-title animated flipInX">主题文档 - 基本概念</h1><div class="post-meta">
            <div class="post-meta-line"><span class="post-author"><a href="https://dillonzq.com" title="Author" target="_blank" rel="noopener noreffer author" class="author"><i class="fas fa-user-circle fa-fw"></i>Dillon</a></span>&nbsp;<span class="post-category">收录于 <a href="/categories/documentation/"><i class="far fa-folder fa-fw"></i>文档</a></span></div>
            <div class="post-meta-line"><i class="far fa-calendar-alt fa-fw"></i>&nbsp;<time datetime="2020-03-06">2020-03-06</time>&nbsp;<i class="fas fa-pencil-alt fa-fw"></i>&nbsp;约 6434 字&nbsp;
                <i class="far fa-clock fa-fw"></i>&nbsp;预计阅读 13 分钟&nbsp;</div>
        </div><div class="featured-image"><img
        class="lazyload"
        src="/svg/loading.min.svg"
        data-src="/posts/theme-documentation-basics/featured-image.jpg"
        data-srcset="/posts/theme-documentation-basics/featured-image.jpg, /posts/theme-documentation-basics/featured-image.jpg 1.5x, /posts/theme-documentation-basics/featured-image.jpg 2x"
        data-sizes="auto"
        alt="/posts/theme-documentation-basics/featured-image.jpg"
        title="探索 Hugo - LoveIt 主题的全部内容和背后的核心概念." /></div><div class="details toc" id="toc-static"  kept="">
                <div class="details-summary toc-title">
                    <span>目录</span>
                    <span><i class="details-icon fas fa-angle-right"></i></span>
                </div>
                <div class="details-content toc-content" id="toc-content-static"><nav id="TableOfContents">
  <ul>
    <li>
      <ul>
        <li><a href="#1-准备">1 准备</a></li>
        <li><a href="#2-安装">2 安装</a>
          <ul>
            <li><a href="#21-创建你的项目">2.1 创建你的项目</a></li>
            <li><a href="#22-安装主题">2.2 安装主题</a></li>
            <li><a href="#basic-configuration">2.3 基础配置</a></li>
            <li><a href="#24-创建你的第一篇文章">2.4 创建你的第一篇文章</a></li>
            <li><a href="#25-在本地启动网站">2.5 在本地启动网站</a></li>
            <li><a href="#26-构建网站">2.6 构建网站</a></li>
          </ul>
        </li>
        <li><a href="#3-配置">3 配置</a>
          <ul>
            <li><a href="#site-configuration">3.1 网站配置</a></li>
            <li><a href="#32-网站图标-浏览器配置-网站清单">3.2 网站图标, 浏览器配置, 网站清单</a></li>
            <li><a href="#33-自定义样式">3.3 自定义样式</a></li>
          </ul>
        </li>
        <li><a href="#4-多语言和-i18n">4 多语言和 i18n</a>
          <ul>
            <li><a href="#language-compatibility">4.1 兼容性</a></li>
            <li><a href="#42-基本配置">4.2 基本配置</a></li>
            <li><a href="#43-修改默认的翻译字符串">4.3 修改默认的翻译字符串</a></li>
          </ul>
        </li>
        <li><a href="#5-搜索">5 搜索</a>
          <ul>
            <li><a href="#51-输出配置">5.1 输出配置</a></li>
            <li><a href="#52-搜索配置">5.2 搜索配置</a></li>
          </ul>
        </li>
      </ul>
    </li>
  </ul>
</nav></div>
            </div><div class="content" id="content"><p>探索 Hugo - <strong>LoveIt</strong> 主题的全部内容和背后的核心概念.</p>
<h2 id="1-准备">1 准备</h2>
<p>由于 Hugo 提供的便利性, <a href="https://gohugo.io/" target="_blank" rel="noopener noreffer">Hugo</a> 本身是这个主题唯一的依赖.</p>
<p>直接安装满足你操作系统 (<strong>Windows</strong>, <strong>Linux</strong>, <strong>macOS</strong>) 的最新版本 <a href="https://gohugo.io/getting-started/installing/" target="_blank" rel="noopener noreffer">:(far fa-file-archive fa-fw): Hugo (&gt; 0.62.0)</a>.</p>
<div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>为什么不支持早期版本的 Hugo?<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">由于 <a href="https://gohugo.io/getting-started/configuration-markup#markdown-render-hooks" target="_blank" rel="noopener noreffer">Markdown 渲染钩子函数</a> 在 <a href="https://gohugo.io/news/0.62.0-relnotes/" target="_blank" rel="noopener noreffer">Hugo 圣诞节版本</a> 中被引入, 本主题只支持高于 <strong>0.62.0</strong> 的 Hugo 版本.</div>
        </div>
    </div>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>推荐使用 Hugo extended 版本<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">由于这个主题的一些特性需要将 :(fab fa-sass fa-fw): SCSS 转换为 :(fab fa-css3 fa-fw): CSS, 推荐使用 Hugo <strong>extended</strong> 版本来获得更好的使用体验.</div>
        </div>
    </div>
<h2 id="2-安装">2 安装</h2>
<p>以下步骤可帮助你初始化新网站. 如果你根本不了解 Hugo, 我们强烈建议你按照此 <a href="https://gohugo.io/getting-started/quick-start/" target="_blank" rel="noopener noreffer">快速入门文档</a> 进一步了解它.</p>
<h3 id="21-创建你的项目">2.1 创建你的项目</h3>
<p>Hugo 提供了一个 <code>new</code> 命令来创建一个新的网站:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">hugo new site my_website
<span class="nb">cd</span> my_website
</code></pre></td></tr></table>
</div>
</div><h3 id="22-安装主题">2.2 安装主题</h3>
<p><strong>LoveIt</strong> 主题的仓库是: <a href="https://github.com/dillonzq/LoveIt" target="_blank" rel="noopener noreffer">https://github.com/dillonzq/LoveIt</a>.</p>
<p>你可以下载主题的 <a href="https://github.com/dillonzq/LoveIt/releases" target="_blank" rel="noopener noreffer">最新版本 :(far fa-file-archive fa-fw): .zip 文件</a> 并且解压放到 <code>themes</code> 目录.</p>
<p>另外, 也可以直接把这个主题克隆到 <code>themes</code> 目录:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">git clone https://github.com/dillonzq/LoveIt.git themes/LoveIt
</code></pre></td></tr></table>
</div>
</div><p>或者, 初始化你的项目目录为 git 仓库, 并且把主题仓库作为你的网站目录的子模块:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">git init
git submodule add https://github.com/dillonzq/LoveIt.git themes/LoveIt
</code></pre></td></tr></table>
</div>
</div><h3 id="basic-configuration">2.3 基础配置</h3>
<p>以下是 LoveIt 主题的基本配置:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt"> 1
</span><span class="lnt"> 2
</span><span class="lnt"> 3
</span><span class="lnt"> 4
</span><span class="lnt"> 5
</span><span class="lnt"> 6
</span><span class="lnt"> 7
</span><span class="lnt"> 8
</span><span class="lnt"> 9
</span><span class="lnt">10
</span><span class="lnt">11
</span><span class="lnt">12
</span><span class="lnt">13
</span><span class="lnt">14
</span><span class="lnt">15
</span><span class="lnt">16
</span><span class="lnt">17
</span><span class="lnt">18
</span><span class="lnt">19
</span><span class="lnt">20
</span><span class="lnt">21
</span><span class="lnt">22
</span><span class="lnt">23
</span><span class="lnt">24
</span><span class="lnt">25
</span><span class="lnt">26
</span><span class="lnt">27
</span><span class="lnt">28
</span><span class="lnt">29
</span><span class="lnt">30
</span><span class="lnt">31
</span><span class="lnt">32
</span><span class="lnt">33
</span><span class="lnt">34
</span><span class="lnt">35
</span><span class="lnt">36
</span><span class="lnt">37
</span><span class="lnt">38
</span><span class="lnt">39
</span><span class="lnt">40
</span><span class="lnt">41
</span><span class="lnt">42
</span><span class="lnt">43
</span><span class="lnt">44
</span><span class="lnt">45
</span><span class="lnt">46
</span><span class="lnt">47
</span><span class="lnt">48
</span><span class="lnt">49
</span><span class="lnt">50
</span><span class="lnt">51
</span><span class="lnt">52
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="nx">baseURL</span> <span class="p">=</span> <span class="s2">&#34;http://example.org/&#34;</span>
<span class="c"># [en, zh-cn, fr, ...] 设置默认的语言</span>
<span class="nx">defaultContentLanguage</span> <span class="p">=</span> <span class="s2">&#34;zh-cn&#34;</span>
<span class="c"># 网站语言, 仅在这里 CN 大写</span>
<span class="nx">languageCode</span> <span class="p">=</span> <span class="s2">&#34;zh-CN&#34;</span>
<span class="c"># 是否包括中日韩文字</span>
<span class="nx">hasCJKLanguage</span> <span class="p">=</span> <span class="kc">true</span>
<span class="c"># 网站标题</span>
<span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;我的全新 Hugo 网站&#34;</span>

<span class="c"># 更改使用 Hugo 构建网站时使用的默认主题</span>
<span class="nx">theme</span> <span class="p">=</span> <span class="s2">&#34;LoveIt&#34;</span>

<span class="p">[</span><span class="nx">params</span><span class="p">]</span>
  <span class="c"># LoveIt 主题版本</span>
  <span class="nx">version</span> <span class="p">=</span> <span class="s2">&#34;0.2.X&#34;</span>

<span class="p">[</span><span class="nx">menu</span><span class="p">]</span>
  <span class="p">[[</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
    <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;posts&#34;</span>
    <span class="c"># 你可以在名称 (允许 HTML 格式) 之前添加其他信息, 例如图标</span>
    <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="c"># 你可以在名称 (允许 HTML 格式) 之后添加其他信息, 例如图标</span>
    <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;文章&#34;</span>
    <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/posts/&#34;</span>
    <span class="c"># 当你将鼠标悬停在此菜单链接上时, 将显示的标题</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">1</span>
  <span class="p">[[</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
    <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;tags&#34;</span>
    <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;标签&#34;</span>
    <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/tags/&#34;</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">2</span>
  <span class="p">[[</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
    <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;categories&#34;</span>
    <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;分类&#34;</span>
    <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/categories/&#34;</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">3</span>

<span class="c"># Hugo 解析文档的配置</span>
<span class="p">[</span><span class="nx">markup</span><span class="p">]</span>
  <span class="c"># 语法高亮设置 (https://gohugo.io/content-management/syntax-highlighting)</span>
  <span class="p">[</span><span class="nx">markup</span><span class="p">.</span><span class="nx">highlight</span><span class="p">]</span>
    <span class="c"># false 是必要的设置 (https://github.com/dillonzq/LoveIt/issues/158)</span>
    <span class="nx">noClasses</span> <span class="p">=</span> <span class="kc">false</span>
</code></pre></td></tr></table>
</div>
</div><div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>注意<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">在构建网站时, 你可以使用 <code>--theme</code> 选项设置主题. 但是, 我建议你修改配置文件 (<strong>config.toml</strong>) 将本主题设置为默认主题.</div>
        </div>
    </div>
<h3 id="24-创建你的第一篇文章">2.4 创建你的第一篇文章</h3>
<p>以下是创建第一篇文章的方法:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">hugo new posts/first_post.md
</code></pre></td></tr></table>
</div>
</div><p>通过添加一些示例内容并替换文件开头的标题, 你可以随意编辑文章.</p>
<div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>注意<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">默认情况下, 所有文章和页面均作为草稿创建. 如果想要渲染这些页面, 请从元数据中删除属性 <code>draft: true</code>, 设置属性 <code>draft: false</code> 或者为 <code>hugo</code> 命令添加 <code>-D</code>/<code>--buildDrafts</code> 参数.</div>
        </div>
    </div>
<h3 id="25-在本地启动网站">2.5 在本地启动网站</h3>
<p>使用以下命令启动网站:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">hugo serve
</code></pre></td></tr></table>
</div>
</div><p>去查看 <code>http://localhost:1313</code>.</p>
<p><figure><a class="lightgallery" href="/posts/theme-documentation-basics/basic-configuration-preview.zh-cn.png" title="基本配置下的预览" data-thumbnail="/posts/theme-documentation-basics/basic-configuration-preview.zh-cn.png" data-sub-html="<h2>基本配置下的预览</h2><p>基本配置下的预览</p>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="basic-configuration-preview.zh-cn.png"
            data-srcset="/posts/theme-documentation-basics/basic-configuration-preview.zh-cn.png, basic-configuration-preview.zh-cn.png 1.5x, /posts/theme-documentation-basics/basic-configuration-preview.zh-cn.png 2x"
            data-sizes="auto"
            alt="/posts/theme-documentation-basics/basic-configuration-preview.zh-cn.png" />
    </a><figcaption class="image-caption">基本配置下的预览</figcaption>
    </figure></p>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>技巧<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">当你运行 <code>hugo serve</code> 时, 当文件内容更改时, 页面会随着更改自动刷新.</div>
        </div>
    </div>
<div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>注意<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content"><p>由于本主题使用了 Hugo 中的 <code>.Scratch</code> 来实现一些特性,
非常建议你为 <code>hugo server</code> 命令添加 <code>--disableFastRender</code> 参数来实时预览你正在编辑的文章页面.</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">hugo serve --disableFastRender
</code></pre></td></tr></table>
</div>
</div></div>
        </div>
    </div>
<h3 id="26-构建网站">2.6 构建网站</h3>
<p>当你准备好部署你的网站时, 运行以下命令:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-bash" data-lang="bash">hugo
</code></pre></td></tr></table>
</div>
</div><p>会生成一个 <code>public</code> 目录, 其中包含你网站的所有静态内容和资源. 现在可以将其部署在任何 Web 服务器上.</p>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>技巧<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">网站内容可以通过 <a href="https://www.netlify.com/" target="_blank" rel="noopener noreffer">Netlify</a> 自动发布和托管 (了解有关<a href="https://www.netlify.com/blog/2015/07/30/hosting-hugo-on-netlifyinsanely-fast-deploys/" target="_blank" rel="noopener noreffer">通过 Netlify 进行 HUGO 自动化部署</a> 的更多信息).
或者, 您可以使用 <a href="https://gohugo.io/hosting-and-deployment/hosting-on-aws-amplify/" target="_blank" rel="noopener noreffer">AWS Amplify</a>, <a href="https://gohugo.io/hosting-and-deployment/hosting-on-github/" target="_blank" rel="noopener noreffer">Github pages</a>, <a href="https://gohugo.io/hosting-and-deployment/hosting-on-render/" target="_blank" rel="noopener noreffer">Render</a> 以及更多&hellip;</div>
        </div>
    </div>
<h2 id="3-配置">3 配置</h2>
<h3 id="site-configuration">3.1 网站配置</h3>
<p>除了 <a href="https://gohugo.io/overview/configuration/" target="_blank" rel="noopener noreffer">Hugo 全局配置</a> 和 <a href="#basic-configuration" rel="">菜单配置</a> 之外, <strong>LoveIt</strong> 主题还允许您在网站配置中定义以下参数 (这是一个示例 <code>config.toml</code>, 其内容为默认值).</p>
<p>请打开下面的代码块查看完整的示例配置 :(far fa-hand-point-down fa-fw)::</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">  1
</span><span class="lnt">  2
</span><span class="lnt">  3
</span><span class="lnt">  4
</span><span class="lnt">  5
</span><span class="lnt">  6
</span><span class="lnt">  7
</span><span class="lnt">  8
</span><span class="lnt">  9
</span><span class="lnt"> 10
</span><span class="lnt"> 11
</span><span class="lnt"> 12
</span><span class="lnt"> 13
</span><span class="lnt"> 14
</span><span class="lnt"> 15
</span><span class="lnt"> 16
</span><span class="lnt"> 17
</span><span class="lnt"> 18
</span><span class="lnt"> 19
</span><span class="lnt"> 20
</span><span class="lnt"> 21
</span><span class="lnt"> 22
</span><span class="lnt"> 23
</span><span class="lnt"> 24
</span><span class="lnt"> 25
</span><span class="lnt"> 26
</span><span class="lnt"> 27
</span><span class="lnt"> 28
</span><span class="lnt"> 29
</span><span class="lnt"> 30
</span><span class="lnt"> 31
</span><span class="lnt"> 32
</span><span class="lnt"> 33
</span><span class="lnt"> 34
</span><span class="lnt"> 35
</span><span class="lnt"> 36
</span><span class="lnt"> 37
</span><span class="lnt"> 38
</span><span class="lnt"> 39
</span><span class="lnt"> 40
</span><span class="lnt"> 41
</span><span class="lnt"> 42
</span><span class="lnt"> 43
</span><span class="lnt"> 44
</span><span class="lnt"> 45
</span><span class="lnt"> 46
</span><span class="lnt"> 47
</span><span class="lnt"> 48
</span><span class="lnt"> 49
</span><span class="lnt"> 50
</span><span class="lnt"> 51
</span><span class="lnt"> 52
</span><span class="lnt"> 53
</span><span class="lnt"> 54
</span><span class="lnt"> 55
</span><span class="lnt"> 56
</span><span class="lnt"> 57
</span><span class="lnt"> 58
</span><span class="lnt"> 59
</span><span class="lnt"> 60
</span><span class="lnt"> 61
</span><span class="lnt"> 62
</span><span class="lnt"> 63
</span><span class="lnt"> 64
</span><span class="lnt"> 65
</span><span class="lnt"> 66
</span><span class="lnt"> 67
</span><span class="lnt"> 68
</span><span class="lnt"> 69
</span><span class="lnt"> 70
</span><span class="lnt"> 71
</span><span class="lnt"> 72
</span><span class="lnt"> 73
</span><span class="lnt"> 74
</span><span class="lnt"> 75
</span><span class="lnt"> 76
</span><span class="lnt"> 77
</span><span class="lnt"> 78
</span><span class="lnt"> 79
</span><span class="lnt"> 80
</span><span class="lnt"> 81
</span><span class="lnt"> 82
</span><span class="lnt"> 83
</span><span class="lnt"> 84
</span><span class="lnt"> 85
</span><span class="lnt"> 86
</span><span class="lnt"> 87
</span><span class="lnt"> 88
</span><span class="lnt"> 89
</span><span class="lnt"> 90
</span><span class="lnt"> 91
</span><span class="lnt"> 92
</span><span class="lnt"> 93
</span><span class="lnt"> 94
</span><span class="lnt"> 95
</span><span class="lnt"> 96
</span><span class="lnt"> 97
</span><span class="lnt"> 98
</span><span class="lnt"> 99
</span><span class="lnt">100
</span><span class="lnt">101
</span><span class="lnt">102
</span><span class="lnt">103
</span><span class="lnt">104
</span><span class="lnt">105
</span><span class="lnt">106
</span><span class="lnt">107
</span><span class="lnt">108
</span><span class="lnt">109
</span><span class="lnt">110
</span><span class="lnt">111
</span><span class="lnt">112
</span><span class="lnt">113
</span><span class="lnt">114
</span><span class="lnt">115
</span><span class="lnt">116
</span><span class="lnt">117
</span><span class="lnt">118
</span><span class="lnt">119
</span><span class="lnt">120
</span><span class="lnt">121
</span><span class="lnt">122
</span><span class="lnt">123
</span><span class="lnt">124
</span><span class="lnt">125
</span><span class="lnt">126
</span><span class="lnt">127
</span><span class="lnt">128
</span><span class="lnt">129
</span><span class="lnt">130
</span><span class="lnt">131
</span><span class="lnt">132
</span><span class="lnt">133
</span><span class="lnt">134
</span><span class="lnt">135
</span><span class="lnt">136
</span><span class="lnt">137
</span><span class="lnt">138
</span><span class="lnt">139
</span><span class="lnt">140
</span><span class="lnt">141
</span><span class="lnt">142
</span><span class="lnt">143
</span><span class="lnt">144
</span><span class="lnt">145
</span><span class="lnt">146
</span><span class="lnt">147
</span><span class="lnt">148
</span><span class="lnt">149
</span><span class="lnt">150
</span><span class="lnt">151
</span><span class="lnt">152
</span><span class="lnt">153
</span><span class="lnt">154
</span><span class="lnt">155
</span><span class="lnt">156
</span><span class="lnt">157
</span><span class="lnt">158
</span><span class="lnt">159
</span><span class="lnt">160
</span><span class="lnt">161
</span><span class="lnt">162
</span><span class="lnt">163
</span><span class="lnt">164
</span><span class="lnt">165
</span><span class="lnt">166
</span><span class="lnt">167
</span><span class="lnt">168
</span><span class="lnt">169
</span><span class="lnt">170
</span><span class="lnt">171
</span><span class="lnt">172
</span><span class="lnt">173
</span><span class="lnt">174
</span><span class="lnt">175
</span><span class="lnt">176
</span><span class="lnt">177
</span><span class="lnt">178
</span><span class="lnt">179
</span><span class="lnt">180
</span><span class="lnt">181
</span><span class="lnt">182
</span><span class="lnt">183
</span><span class="lnt">184
</span><span class="lnt">185
</span><span class="lnt">186
</span><span class="lnt">187
</span><span class="lnt">188
</span><span class="lnt">189
</span><span class="lnt">190
</span><span class="lnt">191
</span><span class="lnt">192
</span><span class="lnt">193
</span><span class="lnt">194
</span><span class="lnt">195
</span><span class="lnt">196
</span><span class="lnt">197
</span><span class="lnt">198
</span><span class="lnt">199
</span><span class="lnt">200
</span><span class="lnt">201
</span><span class="lnt">202
</span><span class="lnt">203
</span><span class="lnt">204
</span><span class="lnt">205
</span><span class="lnt">206
</span><span class="lnt">207
</span><span class="lnt">208
</span><span class="lnt">209
</span><span class="lnt">210
</span><span class="lnt">211
</span><span class="lnt">212
</span><span class="lnt">213
</span><span class="lnt">214
</span><span class="lnt">215
</span><span class="lnt">216
</span><span class="lnt">217
</span><span class="lnt">218
</span><span class="lnt">219
</span><span class="lnt">220
</span><span class="lnt">221
</span><span class="lnt">222
</span><span class="lnt">223
</span><span class="lnt">224
</span><span class="lnt">225
</span><span class="lnt">226
</span><span class="lnt">227
</span><span class="lnt">228
</span><span class="lnt">229
</span><span class="lnt">230
</span><span class="lnt">231
</span><span class="lnt">232
</span><span class="lnt">233
</span><span class="lnt">234
</span><span class="lnt">235
</span><span class="lnt">236
</span><span class="lnt">237
</span><span class="lnt">238
</span><span class="lnt">239
</span><span class="lnt">240
</span><span class="lnt">241
</span><span class="lnt">242
</span><span class="lnt">243
</span><span class="lnt">244
</span><span class="lnt">245
</span><span class="lnt">246
</span><span class="lnt">247
</span><span class="lnt">248
</span><span class="lnt">249
</span><span class="lnt">250
</span><span class="lnt">251
</span><span class="lnt">252
</span><span class="lnt">253
</span><span class="lnt">254
</span><span class="lnt">255
</span><span class="lnt">256
</span><span class="lnt">257
</span><span class="lnt">258
</span><span class="lnt">259
</span><span class="lnt">260
</span><span class="lnt">261
</span><span class="lnt">262
</span><span class="lnt">263
</span><span class="lnt">264
</span><span class="lnt">265
</span><span class="lnt">266
</span><span class="lnt">267
</span><span class="lnt">268
</span><span class="lnt">269
</span><span class="lnt">270
</span><span class="lnt">271
</span><span class="lnt">272
</span><span class="lnt">273
</span><span class="lnt">274
</span><span class="lnt">275
</span><span class="lnt">276
</span><span class="lnt">277
</span><span class="lnt">278
</span><span class="lnt">279
</span><span class="lnt">280
</span><span class="lnt">281
</span><span class="lnt">282
</span><span class="lnt">283
</span><span class="lnt">284
</span><span class="lnt">285
</span><span class="lnt">286
</span><span class="lnt">287
</span><span class="lnt">288
</span><span class="lnt">289
</span><span class="lnt">290
</span><span class="lnt">291
</span><span class="lnt">292
</span><span class="lnt">293
</span><span class="lnt">294
</span><span class="lnt">295
</span><span class="lnt">296
</span><span class="lnt">297
</span><span class="lnt">298
</span><span class="lnt">299
</span><span class="lnt">300
</span><span class="lnt">301
</span><span class="lnt">302
</span><span class="lnt">303
</span><span class="lnt">304
</span><span class="lnt">305
</span><span class="lnt">306
</span><span class="lnt">307
</span><span class="lnt">308
</span><span class="lnt">309
</span><span class="lnt">310
</span><span class="lnt">311
</span><span class="lnt">312
</span><span class="lnt">313
</span><span class="lnt">314
</span><span class="lnt">315
</span><span class="lnt">316
</span><span class="lnt">317
</span><span class="lnt">318
</span><span class="lnt">319
</span><span class="lnt">320
</span><span class="lnt">321
</span><span class="lnt">322
</span><span class="lnt">323
</span><span class="lnt">324
</span><span class="lnt">325
</span><span class="lnt">326
</span><span class="lnt">327
</span><span class="lnt">328
</span><span class="lnt">329
</span><span class="lnt">330
</span><span class="lnt">331
</span><span class="lnt">332
</span><span class="lnt">333
</span><span class="lnt">334
</span><span class="lnt">335
</span><span class="lnt">336
</span><span class="lnt">337
</span><span class="lnt">338
</span><span class="lnt">339
</span><span class="lnt">340
</span><span class="lnt">341
</span><span class="lnt">342
</span><span class="lnt">343
</span><span class="lnt">344
</span><span class="lnt">345
</span><span class="lnt">346
</span><span class="lnt">347
</span><span class="lnt">348
</span><span class="lnt">349
</span><span class="lnt">350
</span><span class="lnt">351
</span><span class="lnt">352
</span><span class="lnt">353
</span><span class="lnt">354
</span><span class="lnt">355
</span><span class="lnt">356
</span><span class="lnt">357
</span><span class="lnt">358
</span><span class="lnt">359
</span><span class="lnt">360
</span><span class="lnt">361
</span><span class="lnt">362
</span><span class="lnt">363
</span><span class="lnt">364
</span><span class="lnt">365
</span><span class="lnt">366
</span><span class="lnt">367
</span><span class="lnt">368
</span><span class="lnt">369
</span><span class="lnt">370
</span><span class="lnt">371
</span><span class="lnt">372
</span><span class="lnt">373
</span><span class="lnt">374
</span><span class="lnt">375
</span><span class="lnt">376
</span><span class="lnt">377
</span><span class="lnt">378
</span><span class="lnt">379
</span><span class="lnt">380
</span><span class="lnt">381
</span><span class="lnt">382
</span><span class="lnt">383
</span><span class="lnt">384
</span><span class="lnt">385
</span><span class="lnt">386
</span><span class="lnt">387
</span><span class="lnt">388
</span><span class="lnt">389
</span><span class="lnt">390
</span><span class="lnt">391
</span><span class="lnt">392
</span><span class="lnt">393
</span><span class="lnt">394
</span><span class="lnt">395
</span><span class="lnt">396
</span><span class="lnt">397
</span><span class="lnt">398
</span><span class="lnt">399
</span><span class="lnt">400
</span><span class="lnt">401
</span><span class="lnt">402
</span><span class="lnt">403
</span><span class="lnt">404
</span><span class="lnt">405
</span><span class="lnt">406
</span><span class="lnt">407
</span><span class="lnt">408
</span><span class="lnt">409
</span><span class="lnt">410
</span><span class="lnt">411
</span><span class="lnt">412
</span><span class="lnt">413
</span><span class="lnt">414
</span><span class="lnt">415
</span><span class="lnt">416
</span><span class="lnt">417
</span><span class="lnt">418
</span><span class="lnt">419
</span><span class="lnt">420
</span><span class="lnt">421
</span><span class="lnt">422
</span><span class="lnt">423
</span><span class="lnt">424
</span><span class="lnt">425
</span><span class="lnt">426
</span><span class="lnt">427
</span><span class="lnt">428
</span><span class="lnt">429
</span><span class="lnt">430
</span><span class="lnt">431
</span><span class="lnt">432
</span><span class="lnt">433
</span><span class="lnt">434
</span><span class="lnt">435
</span><span class="lnt">436
</span><span class="lnt">437
</span><span class="lnt">438
</span><span class="lnt">439
</span><span class="lnt">440
</span><span class="lnt">441
</span><span class="lnt">442
</span><span class="lnt">443
</span><span class="lnt">444
</span><span class="lnt">445
</span><span class="lnt">446
</span><span class="lnt">447
</span><span class="lnt">448
</span><span class="lnt">449
</span><span class="lnt">450
</span><span class="lnt">451
</span><span class="lnt">452
</span><span class="lnt">453
</span><span class="lnt">454
</span><span class="lnt">455
</span><span class="lnt">456
</span><span class="lnt">457
</span><span class="lnt">458
</span><span class="lnt">459
</span><span class="lnt">460
</span><span class="lnt">461
</span><span class="lnt">462
</span><span class="lnt">463
</span><span class="lnt">464
</span><span class="lnt">465
</span><span class="lnt">466
</span><span class="lnt">467
</span><span class="lnt">468
</span><span class="lnt">469
</span><span class="lnt">470
</span><span class="lnt">471
</span><span class="lnt">472
</span><span class="lnt">473
</span><span class="lnt">474
</span><span class="lnt">475
</span><span class="lnt">476
</span><span class="lnt">477
</span><span class="lnt">478
</span><span class="lnt">479
</span><span class="lnt">480
</span><span class="lnt">481
</span><span class="lnt">482
</span><span class="lnt">483
</span><span class="lnt">484
</span><span class="lnt">485
</span><span class="lnt">486
</span><span class="lnt">487
</span><span class="lnt">488
</span><span class="lnt">489
</span><span class="lnt">490
</span><span class="lnt">491
</span><span class="lnt">492
</span><span class="lnt">493
</span><span class="lnt">494
</span><span class="lnt">495
</span><span class="lnt">496
</span><span class="lnt">497
</span><span class="lnt">498
</span><span class="lnt">499
</span><span class="lnt">500
</span><span class="lnt">501
</span><span class="lnt">502
</span><span class="lnt">503
</span><span class="lnt">504
</span><span class="lnt">505
</span><span class="lnt">506
</span><span class="lnt">507
</span><span class="lnt">508
</span><span class="lnt">509
</span><span class="lnt">510
</span><span class="lnt">511
</span><span class="lnt">512
</span><span class="lnt">513
</span><span class="lnt">514
</span><span class="lnt">515
</span><span class="lnt">516
</span><span class="lnt">517
</span><span class="lnt">518
</span><span class="lnt">519
</span><span class="lnt">520
</span><span class="lnt">521
</span><span class="lnt">522
</span><span class="lnt">523
</span><span class="lnt">524
</span><span class="lnt">525
</span><span class="lnt">526
</span><span class="lnt">527
</span><span class="lnt">528
</span><span class="lnt">529
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="p">[</span><span class="nx">params</span><span class="p">]</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-changed.min.svg"
        data-srcset="/svg/version/0.2.0-changed.min.svg, /svg/version/0.2.0-changed.min.svg 1.5x, /svg/version/0.2.0-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.0"
        title="LoveIt 更改 | 0.2.0" /></a> LoveIt 主题版本</span>
  <span class="nx">version</span> <span class="p">=</span> <span class="s2">&#34;0.2.X&#34;</span>
  <span class="c"># 网站描述</span>
  <span class="nx">description</span> <span class="p">=</span> <span class="s2">&#34;这是我的全新 Hugo 网站&#34;</span>
  <span class="c"># 网站关键词</span>
  <span class="nx">keywords</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;Theme&#34;</span><span class="p">,</span> <span class="s2">&#34;Hugo&#34;</span><span class="p">]</span>
  <span class="c"># 网站默认主题样式 (&#34;light&#34;, &#34;dark&#34;, &#34;auto&#34;)</span>
  <span class="nx">defaultTheme</span> <span class="p">=</span> <span class="s2">&#34;auto&#34;</span>
  <span class="c"># 公共 git 仓库路径，仅在 enableGitInfo 设为 true 时有效</span>
  <span class="nx">gitRepo</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.1.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.1.1-new.min.svg"
        data-srcset="/svg/version/0.1.1-new.min.svg, /svg/version/0.1.1-new.min.svg 1.5x, /svg/version/0.1.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.1.1"
        title="LoveIt 新增 | 0.1.1" /></a> 哪种哈希函数用来 SRI, 为空时表示不使用 SRI</span>
  <span class="c"># (&#34;sha256&#34;, &#34;sha384&#34;, &#34;sha512&#34;, &#34;md5&#34;)</span>
  <span class="nx">fingerprint</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 日期格式</span>
  <span class="nx">dateFormat</span> <span class="p">=</span> <span class="s2">&#34;2006-01-02&#34;</span>
  <span class="c"># 网站图片, 用于 Open Graph 和 Twitter Cards</span>
  <span class="nx">images</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;/logo.png&#34;</span><span class="p">]</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 应用图标配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">app</span><span class="p">]</span>
    <span class="c"># 当添加到 iOS 主屏幕或者 Android 启动器时的标题, 覆盖默认标题</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;LoveIt&#34;</span>
    <span class="c"># 是否隐藏网站图标资源链接</span>
    <span class="nx">noFavicon</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># 更现代的 SVG 网站图标, 可替代旧的 .png 和 .ico 文件</span>
    <span class="nx">svgFavicon</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="c"># Android 浏览器主题色</span>
    <span class="nx">themeColor</span> <span class="p">=</span> <span class="s2">&#34;#ffffff&#34;</span>
    <span class="c"># Safari 图标颜色</span>
    <span class="nx">iconColor</span> <span class="p">=</span> <span class="s2">&#34;#5bbad5&#34;</span>
    <span class="c"># Windows v8-10磁贴颜色</span>
    <span class="nx">tileColor</span> <span class="p">=</span> <span class="s2">&#34;#da532c&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 搜索配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">search</span><span class="p">]</span>
    <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># 搜索引擎的类型 (&#34;lunr&#34;, &#34;algolia&#34;)</span>
    <span class="nx">type</span> <span class="p">=</span> <span class="s2">&#34;lunr&#34;</span>
    <span class="c"># 文章内容最长索引长度</span>
    <span class="nx">contentLength</span> <span class="p">=</span> <span class="mi">4000</span>
    <span class="c"># 搜索框的占位提示语</span>
    <span class="nx">placeholder</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.1-new.min.svg"
        data-srcset="/svg/version/0.2.1-new.min.svg, /svg/version/0.2.1-new.min.svg 1.5x, /svg/version/0.2.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.1"
        title="LoveIt 新增 | 0.2.1" /></a> 最大结果数目</span>
    <span class="nx">maxResultLength</span> <span class="p">=</span> <span class="mi">10</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.3" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.3-new.min.svg"
        data-srcset="/svg/version/0.2.3-new.min.svg, /svg/version/0.2.3-new.min.svg 1.5x, /svg/version/0.2.3-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.3"
        title="LoveIt 新增 | 0.2.3" /></a> 结果内容片段长度</span>
    <span class="nx">snippetLength</span> <span class="p">=</span> <span class="mi">50</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.1-new.min.svg"
        data-srcset="/svg/version/0.2.1-new.min.svg, /svg/version/0.2.1-new.min.svg 1.5x, /svg/version/0.2.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.1"
        title="LoveIt 新增 | 0.2.1" /></a> 搜索结果中高亮部分的 HTML 标签</span>
    <span class="nx">highlightTag</span> <span class="p">=</span> <span class="s2">&#34;em&#34;</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.4" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.4-new.min.svg"
        data-srcset="/svg/version/0.2.4-new.min.svg, /svg/version/0.2.4-new.min.svg 1.5x, /svg/version/0.2.4-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.4"
        title="LoveIt 新增 | 0.2.4" /></a> 是否在搜索索引中使用基于 baseURL 的绝对路径</span>
    <span class="nx">absoluteURL</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">search</span><span class="p">.</span><span class="nx">algolia</span><span class="p">]</span>
      <span class="nx">index</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">appID</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">searchKey</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># 页面头部导航栏配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">header</span><span class="p">]</span>
    <span class="c"># 桌面端导航栏模式 (&#34;fixed&#34;, &#34;normal&#34;, &#34;auto&#34;)</span>
    <span class="nx">desktopMode</span> <span class="p">=</span> <span class="s2">&#34;fixed&#34;</span>
    <span class="c"># 移动端导航栏模式 (&#34;fixed&#34;, &#34;normal&#34;, &#34;auto&#34;)</span>
    <span class="nx">mobileMode</span> <span class="p">=</span> <span class="s2">&#34;auto&#34;</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 页面头部导航栏标题配置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">header</span><span class="p">.</span><span class="nx">title</span><span class="p">]</span>
      <span class="c"># LOGO 的 URL</span>
      <span class="nx">logo</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 标题名称</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 你可以在名称 (允许 HTML 格式) 之前添加其他信息, 例如图标</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 你可以在名称 (允许 HTML 格式) 之后添加其他信息, 例如图标</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.5" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.5-new.min.svg"
        data-srcset="/svg/version/0.2.5-new.min.svg, /svg/version/0.2.5-new.min.svg 1.5x, /svg/version/0.2.5-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.5"
        title="LoveIt 新增 | 0.2.5" /></a> 是否为标题显示打字机动画</span>
      <span class="nx">typeit</span> <span class="p">=</span> <span class="kc">false</span>

  <span class="c"># 页面底部信息配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">footer</span><span class="p">]</span>
    <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 自定义内容 (支持 HTML 格式)</span>
    <span class="nx">custom</span> <span class="p">=</span> <span class="s1">&#39;&#39;</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否显示 Hugo 和主题信息</span>
    <span class="nx">hugo</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否显示版权信息</span>
    <span class="nx">copyright</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否显示作者</span>
    <span class="nx">author</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># 网站创立年份</span>
    <span class="nx">since</span> <span class="p">=</span> <span class="mi">2019</span>
    <span class="c"># ICP 备案信息，仅在中国使用 (支持 HTML 格式)</span>
    <span class="nx">icp</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="c"># 许可协议信息 (支持 HTML 格式)</span>
    <span class="nx">license</span> <span class="p">=</span> <span class="s1">&#39;&lt;a rel=&#34;license external nofollow noopener noreffer&#34; href=&#34;https://creativecommons.org/licenses/by-nc/4.0/&#34; target=&#34;_blank&#34;&gt;CC BY-NC 4.0&lt;/a&gt;&#39;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> Section (所有文章) 页面配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">section</span><span class="p">]</span>
    <span class="c"># section 页面每页显示文章数量</span>
    <span class="nx">paginate</span> <span class="p">=</span> <span class="mi">20</span>
    <span class="c"># 日期格式 (月和日)</span>
    <span class="nx">dateFormat</span> <span class="p">=</span> <span class="s2">&#34;01-02&#34;</span>
    <span class="c"># RSS 文章数目</span>
    <span class="nx">rss</span> <span class="p">=</span> <span class="mi">10</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> List (目录或标签) 页面配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">list</span><span class="p">]</span>
    <span class="c"># list 页面每页显示文章数量</span>
    <span class="nx">paginate</span> <span class="p">=</span> <span class="mi">20</span>
    <span class="c"># 日期格式 (月和日)</span>
    <span class="nx">dateFormat</span> <span class="p">=</span> <span class="s2">&#34;01-02&#34;</span>
    <span class="c"># RSS 文章数目</span>
    <span class="nx">rss</span> <span class="p">=</span> <span class="mi">10</span>

  <span class="c"># 主页配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">home</span><span class="p">]</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> RSS 文章数目</span>
    <span class="nx">rss</span> <span class="p">=</span> <span class="mi">10</span>
    <span class="c"># 主页个人信息</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">home</span><span class="p">.</span><span class="nx">profile</span><span class="p">]</span>
      <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># Gravatar 邮箱，用于优先在主页显示的头像</span>
      <span class="nx">gravatarEmail</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 主页显示头像的 URL</span>
      <span class="nx">avatarURL</span> <span class="p">=</span> <span class="s2">&#34;/images/avatar.png&#34;</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.7" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.7-changed.min.svg"
        data-srcset="/svg/version/0.2.7-changed.min.svg, /svg/version/0.2.7-changed.min.svg 1.5x, /svg/version/0.2.7-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.7"
        title="LoveIt 更改 | 0.2.7" /></a> 主页显示的网站标题 (支持 HTML 格式)</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 主页显示的网站副标题</span>
      <span class="nx">subtitle</span> <span class="p">=</span> <span class="s2">&#34;这是我的全新 Hugo 网站&#34;</span>
      <span class="c"># 是否为副标题显示打字机动画</span>
      <span class="nx">typeit</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 是否显示社交账号</span>
      <span class="nx">social</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 免责声明 (支持 HTML 格式)</span>
      <span class="nx">disclaimer</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="c"># 主页文章列表</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">home</span><span class="p">.</span><span class="nx">posts</span><span class="p">]</span>
      <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 主页每页显示文章数量</span>
      <span class="nx">paginate</span> <span class="p">=</span> <span class="mi">6</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-deleted.min.svg"
        data-srcset="/svg/version/0.2.0-deleted.min.svg, /svg/version/0.2.0-deleted.min.svg 1.5x, /svg/version/0.2.0-deleted.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 删除 | 0.2.0"
        title="LoveIt 删除 | 0.2.0" /></a> 被 params.page 中的 hiddenFromHomePage 替代</span>
      <span class="c"># 当你没有在文章前置参数中设置 &#34;hiddenFromHomePage&#34; 时的默认行为</span>
      <span class="nx">defaultHiddenFromHomePage</span> <span class="p">=</span> <span class="kc">false</span>

  <span class="c"># 作者的社交信息设置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">social</span><span class="p">]</span>
    <span class="nx">GitHub</span> <span class="p">=</span> <span class="s2">&#34;xxxx&#34;</span>
    <span class="nx">Linkedin</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Twitter</span> <span class="p">=</span> <span class="s2">&#34;xxxx&#34;</span>
    <span class="nx">Instagram</span> <span class="p">=</span> <span class="s2">&#34;xxxx&#34;</span>
    <span class="nx">Facebook</span> <span class="p">=</span> <span class="s2">&#34;xxxx&#34;</span>
    <span class="nx">Telegram</span> <span class="p">=</span> <span class="s2">&#34;xxxx&#34;</span>
    <span class="nx">Medium</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Gitlab</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Youtubelegacy</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Youtubecustom</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Youtubechannel</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Tumblr</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Quora</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Keybase</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Pinterest</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Reddit</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Codepen</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">FreeCodeCamp</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Bitbucket</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Stackoverflow</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Weibo</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Odnoklassniki</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">VK</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Flickr</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Xing</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Snapchat</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Soundcloud</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Spotify</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Bandcamp</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Paypal</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Fivehundredpx</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Mix</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Goodreads</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Lastfm</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Foursquare</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Hackernews</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Kickstarter</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Patreon</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Steam</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Twitch</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Strava</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Skype</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Whatsapp</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Zhihu</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Douban</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Angellist</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Slidershare</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Jsfiddle</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Deviantart</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Behance</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Dribbble</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Wordpress</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Vine</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Googlescholar</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Researchgate</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Mastodon</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Thingiverse</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Devto</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Gitea</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">XMPP</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Matrix</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Bilibili</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">Email</span> <span class="p">=</span> <span class="s2">&#34;xxxx@xxxx.com&#34;</span>
    <span class="nx">RSS</span> <span class="p">=</span> <span class="kc">true</span> <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a></span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-changed.min.svg"
        data-srcset="/svg/version/0.2.0-changed.min.svg, /svg/version/0.2.0-changed.min.svg 1.5x, /svg/version/0.2.0-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.0"
        title="LoveIt 更改 | 0.2.0" /></a> 文章页面配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">]</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否在主页隐藏一篇文章</span>
    <span class="nx">hiddenFromHomePage</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否在搜索结果中隐藏一篇文章</span>
    <span class="nx">hiddenFromSearch</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否使用 twemoji</span>
    <span class="nx">twemoji</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># 是否使用 lightgallery</span>
    <span class="nx">lightgallery</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否使用 ruby 扩展语法</span>
    <span class="nx">ruby</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否使用 fraction 扩展语法</span>
    <span class="nx">fraction</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 是否使用 fontawesome 扩展语法</span>
    <span class="nx">fontawesome</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># 是否在文章页面显示原始 Markdown 文档链接</span>
    <span class="nx">linkToMarkdown</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.4" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.4-new.min.svg"
        data-srcset="/svg/version/0.2.4-new.min.svg, /svg/version/0.2.4-new.min.svg 1.5x, /svg/version/0.2.4-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.4"
        title="LoveIt 新增 | 0.2.4" /></a> 是否在 RSS 中显示全文内容</span>
    <span class="nx">rssFullText</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 目录配置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">toc</span><span class="p">]</span>
      <span class="c"># 是否使用目录</span>
      <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.9" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.9-new.min.svg"
        data-srcset="/svg/version/0.2.9-new.min.svg, /svg/version/0.2.9-new.min.svg 1.5x, /svg/version/0.2.9-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.9"
        title="LoveIt 新增 | 0.2.9" /></a> 是否保持使用文章前面的静态目录</span>
      <span class="nx">keepStatic</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 是否使侧边目录自动折叠展开</span>
      <span class="nx">auto</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 代码配置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">code</span><span class="p">]</span>
      <span class="c"># 是否显示代码块的复制按钮</span>
      <span class="nx">copy</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 默认展开显示的代码行数</span>
      <span class="nx">maxShownLines</span> <span class="p">=</span> <span class="mi">10</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-changed.min.svg"
        data-srcset="/svg/version/0.2.0-changed.min.svg, /svg/version/0.2.0-changed.min.svg 1.5x, /svg/version/0.2.0-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.0"
        title="LoveIt 更改 | 0.2.0" /></a> <a href="https://katex.org/" target="_blank" rel="noopener noreffer">KaTeX</a> 数学公式</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">math</span><span class="p">]</span>
      <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 默认块定界符是 $$ ... $$ 和 \\[ ... \\]</span>
      <span class="nx">blockLeftDelimiter</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">blockRightDelimiter</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 默认行内定界符是 $ ... $ 和 \\( ... \\)</span>
      <span class="nx">inlineLeftDelimiter</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">inlineRightDelimiter</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># KaTeX 插件 copy_tex</span>
      <span class="nx">copyTex</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># KaTeX 插件 mhchem</span>
      <span class="nx">mhchem</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> <a href="https://docs.mapbox.com/mapbox-gl-js" target="_blank" rel="noopener noreffer">Mapbox GL JS</a> 配置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">mapbox</span><span class="p">]</span>
      <span class="c"># Mapbox GL JS 的 access token</span>
      <span class="nx">accessToken</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 浅色主题的地图样式</span>
      <span class="nx">lightStyle</span> <span class="p">=</span> <span class="s2">&#34;mapbox://styles/mapbox/light-v9&#34;</span>
      <span class="c"># 深色主题的地图样式</span>
      <span class="nx">darkStyle</span> <span class="p">=</span> <span class="s2">&#34;mapbox://styles/mapbox/dark-v9&#34;</span>
      <span class="c"># 是否添加 <a href="https://docs.mapbox.com/mapbox-gl-js/api#navigationcontrol" target="_blank" rel="noopener noreffer">NavigationControl</a></span>
      <span class="nx">navigation</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 是否添加 <a href="https://docs.mapbox.com/mapbox-gl-js/api#geolocatecontrol" target="_blank" rel="noopener noreffer">GeolocateControl</a></span>
      <span class="nx">geolocate</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 是否添加 <a href="https://docs.mapbox.com/mapbox-gl-js/api#scalecontrol" target="_blank" rel="noopener noreffer">ScaleControl</a></span>
      <span class="nx">scale</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># 是否添加 <a href="https://docs.mapbox.com/mapbox-gl-js/api#fullscreencontrol" target="_blank" rel="noopener noreffer">FullscreenControl</a></span>
      <span class="nx">fullscreen</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-changed.min.svg"
        data-srcset="/svg/version/0.2.0-changed.min.svg, /svg/version/0.2.0-changed.min.svg 1.5x, /svg/version/0.2.0-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.0"
        title="LoveIt 更改 | 0.2.0" /></a> 文章页面的分享信息设置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">share</span><span class="p">]</span>
      <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Twitter</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Facebook</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Linkedin</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Whatsapp</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Pinterest</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Tumblr</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">HackerNews</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Reddit</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">VK</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Buffer</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Xing</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Line</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Instapaper</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Pocket</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Digg</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Stumbleupon</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Flipboard</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Weibo</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Renren</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Myspace</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Blogger</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Baidu</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Odnoklassniki</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Evernote</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">Skype</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Trello</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="nx">Mix</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-changed.min.svg"
        data-srcset="/svg/version/0.2.0-changed.min.svg, /svg/version/0.2.0-changed.min.svg 1.5x, /svg/version/0.2.0-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.0"
        title="LoveIt 更改 | 0.2.0" /></a> 评论系统设置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">]</span>
      <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="c"># <a href="https://disqus.com/" target="_blank" rel="noopener noreffer">Disqus</a> 评论系统设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">disqus</span><span class="p">]</span>
        <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.1.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.1.1-new.min.svg"
        data-srcset="/svg/version/0.1.1-new.min.svg, /svg/version/0.1.1-new.min.svg 1.5x, /svg/version/0.1.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.1.1"
        title="LoveIt 新增 | 0.1.1" /></a></span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="c"># Disqus 的 shortname，用来在文章中启用 Disqus 评论系统</span>
        <span class="nx">shortname</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># <a href="https://github.com/gitalk/gitalk" target="_blank" rel="noopener noreffer">Gitalk</a> 评论系统设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">gitalk</span><span class="p">]</span>
        <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.1.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.1.1-new.min.svg"
        data-srcset="/svg/version/0.1.1-new.min.svg, /svg/version/0.1.1-new.min.svg 1.5x, /svg/version/0.1.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.1.1"
        title="LoveIt 新增 | 0.1.1" /></a></span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="nx">owner</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">repo</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">clientId</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">clientSecret</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># <a href="https://github.com/xCss/Valine" target="_blank" rel="noopener noreffer">Valine</a> 评论系统设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">valine</span><span class="p">]</span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="nx">appId</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">appKey</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">placeholder</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">avatar</span> <span class="p">=</span> <span class="s2">&#34;mp&#34;</span>
        <span class="nx">meta</span><span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">pageSize</span> <span class="p">=</span> <span class="mi">10</span>
        <span class="nx">lang</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">visitor</span> <span class="p">=</span> <span class="kc">true</span>
        <span class="nx">recordIP</span> <span class="p">=</span> <span class="kc">true</span>
        <span class="nx">highlight</span> <span class="p">=</span> <span class="kc">true</span>
        <span class="nx">enableQQ</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="nx">serverURLs</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.6" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.6-new.min.svg"
        data-srcset="/svg/version/0.2.6-new.min.svg, /svg/version/0.2.6-new.min.svg 1.5x, /svg/version/0.2.6-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.6"
        title="LoveIt 新增 | 0.2.6" /></a> emoji 数据文件名称, 默认是 &#34;google.yml&#34;</span>
        <span class="c"># (&#34;apple.yml&#34;, &#34;google.yml&#34;, &#34;facebook.yml&#34;, &#34;twitter.yml&#34;)</span>
        <span class="c"># 位于 &#34;themes/LoveIt/assets/data/emoji/&#34; 目录</span>
        <span class="c"># 可以在你的项目下相同路径存放你自己的数据文件:</span>
        <span class="c"># &#34;assets/data/emoji/&#34;</span>
        <span class="nx">emoji</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># <a href="https://developers.facebook.com/docs/plugins/comments" target="_blank" rel="noopener noreffer">Facebook 评论系统</a>设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">facebook</span><span class="p">]</span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="nx">width</span> <span class="p">=</span> <span class="s2">&#34;100%&#34;</span>
        <span class="nx">numPosts</span> <span class="p">=</span> <span class="mi">10</span>
        <span class="nx">appId</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">languageCode</span> <span class="p">=</span> <span class="s2">&#34;zh_CN&#34;</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> <a href="https://comments.app/" target="_blank" rel="noopener noreffer">Telegram Comments</a> 评论系统设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">telegram</span><span class="p">]</span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="nx">siteID</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">limit</span> <span class="p">=</span> <span class="mi">5</span>
        <span class="nx">height</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">color</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">colorful</span> <span class="p">=</span> <span class="kc">true</span>
        <span class="nx">dislikes</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="nx">outlined</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> <a href="https://commento.io/" target="_blank" rel="noopener noreffer">Commento</a> 评论系统设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">commento</span><span class="p">]</span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
      <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.5" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.5-new.min.svg"
        data-srcset="/svg/version/0.2.5-new.min.svg, /svg/version/0.2.5-new.min.svg 1.5x, /svg/version/0.2.5-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.5"
        title="LoveIt 新增 | 0.2.5" /></a> <a href="https://utteranc.es/" target="_blank" rel="noopener noreffer">Utterances</a> 评论系统设置</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">comment</span><span class="p">.</span><span class="nx">utterances</span><span class="p">]</span>
        <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
        <span class="c"># owner/repo</span>
        <span class="nx">repo</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">issueTerm</span> <span class="p">=</span> <span class="s2">&#34;pathname&#34;</span>
        <span class="nx">label</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">lightTheme</span> <span class="p">=</span> <span class="s2">&#34;github-light&#34;</span>
        <span class="nx">darkTheme</span> <span class="p">=</span> <span class="s2">&#34;github-dark&#34;</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.7" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.7-new.min.svg"
        data-srcset="/svg/version/0.2.7-new.min.svg, /svg/version/0.2.7-new.min.svg 1.5x, /svg/version/0.2.7-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.7"
        title="LoveIt 新增 | 0.2.7" /></a> 第三方库配置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">library</span><span class="p">]</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">library</span><span class="p">.</span><span class="nx">css</span><span class="p">]</span>
        <span class="c"># someCSS = &#34;some.css&#34;</span>
        <span class="c"># 位于 &#34;assets/&#34;</span>
        <span class="c"># 或者</span>
        <span class="c"># someCSS = &#34;https://cdn.example.com/some.css&#34;</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">library</span><span class="p">.</span><span class="nx">js</span><span class="p">]</span>
        <span class="c"># someJavascript = &#34;some.js&#34;</span>
        <span class="c"># 位于 &#34;assets/&#34;</span>
        <span class="c"># 或者</span>
        <span class="c"># someJavascript = &#34;https://cdn.example.com/some.js&#34;</span>
    <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.10" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.10-changed.min.svg"
        data-srcset="/svg/version/0.2.10-changed.min.svg, /svg/version/0.2.10-changed.min.svg 1.5x, /svg/version/0.2.10-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.10"
        title="LoveIt 更改 | 0.2.10" /></a> 页面 SEO 配置</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">seo</span><span class="p">]</span>
      <span class="c"># 图片 URL</span>
      <span class="nx">images</span> <span class="p">=</span> <span class="p">[]</span>
      <span class="c"># 出版者信息</span>
      <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">page</span><span class="p">.</span><span class="nx">seo</span><span class="p">.</span><span class="nx">publisher</span><span class="p">]</span>
        <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
        <span class="nx">logoUrl</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.5" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.5-new.min.svg"
        data-srcset="/svg/version/0.2.5-new.min.svg, /svg/version/0.2.5-new.min.svg 1.5x, /svg/version/0.2.5-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.5"
        title="LoveIt 新增 | 0.2.5" /></a> TypeIt 配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">typeit</span><span class="p">]</span>
    <span class="c"># 每一步的打字速度 (单位是毫秒)</span>
    <span class="nx">speed</span> <span class="p">=</span> <span class="mi">100</span>
    <span class="c"># 光标的闪烁速度 (单位是毫秒)</span>
    <span class="nx">cursorSpeed</span> <span class="p">=</span> <span class="mi">1000</span>
    <span class="c"># 光标的字符 (支持 HTML 格式)</span>
    <span class="nx">cursorChar</span> <span class="p">=</span> <span class="s2">&#34;|&#34;</span>
    <span class="c"># 打字结束之后光标的持续时间 (单位是毫秒, &#34;-1&#34; 代表无限大)</span>
    <span class="nx">duration</span> <span class="p">=</span> <span class="mi">-1</span>

  <span class="c"># 网站验证代码，用于 Google/Bing/Yandex/Pinterest/Baidu</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">verification</span><span class="p">]</span>
    <span class="nx">google</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">bing</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">yandex</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">pinterest</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">baidu</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.10" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.10-new.min.svg"
        data-srcset="/svg/version/0.2.10-new.min.svg, /svg/version/0.2.10-new.min.svg 1.5x, /svg/version/0.2.10-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.10"
        title="LoveIt 新增 | 0.2.10" /></a> 网站 SEO 配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">seo</span><span class="p">]</span>
    <span class="c"># 图片 URL</span>
    <span class="nx">image</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="c"># 缩略图 URL</span>
    <span class="nx">thumbnailUrl</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a> 网站分析配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">analytics</span><span class="p">]</span>
    <span class="nx">enable</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># Google Analytics</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">analytics</span><span class="p">.</span><span class="nx">google</span><span class="p">]</span>
      <span class="nx">id</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 是否匿名化用户 IP</span>
      <span class="nx">anonymizeIP</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># Fathom Analytics</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">analytics</span><span class="p">.</span><span class="nx">fathom</span><span class="p">]</span>
      <span class="nx">id</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="c"># 自行托管追踪器时的主机路径</span>
      <span class="nx">server</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.7" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.7-new.min.svg"
        data-srcset="/svg/version/0.2.7-new.min.svg, /svg/version/0.2.7-new.min.svg 1.5x, /svg/version/0.2.7-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.7"
        title="LoveIt 新增 | 0.2.7" /></a> Cookie 许可配置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">cookieconsent</span><span class="p">]</span>
    <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># 用于 Cookie 许可横幅的文本字符串</span>
    <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">cookieconsent</span><span class="p">.</span><span class="nx">content</span><span class="p">]</span>
      <span class="nx">message</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">dismiss</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">link</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.7" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.7-changed.min.svg"
        data-srcset="/svg/version/0.2.7-changed.min.svg, /svg/version/0.2.7-changed.min.svg 1.5x, /svg/version/0.2.7-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.7"
        title="LoveIt 更改 | 0.2.7" /></a> 第三方库文件的 CDN 设置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">cdn</span><span class="p">]</span>
    <span class="c"># CDN 数据文件名称, 默认不启用</span>
    <span class="c"># (&#34;jsdelivr.yml&#34;)</span>
    <span class="c"># 位于 &#34;themes/LoveIt/assets/data/cdn/&#34; 目录</span>
    <span class="c"># 可以在你的项目下相同路径存放你自己的数据文件:</span>
    <span class="c"># &#34;assets/data/cdn/&#34;</span>
    <span class="nx">data</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.8" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.8-new.min.svg"
        data-srcset="/svg/version/0.2.8-new.min.svg, /svg/version/0.2.8-new.min.svg 1.5x, /svg/version/0.2.8-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.8"
        title="LoveIt 新增 | 0.2.8" /></a> 兼容性设置</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">compatibility</span><span class="p">]</span>
    <span class="c"># 是否使用 Polyfill.io 来兼容旧式浏览器</span>
    <span class="nx">polyfill</span> <span class="p">=</span> <span class="kc">false</span>
    <span class="c"># 是否使用 object-fit-images 来兼容旧式浏览器</span>
    <span class="nx">objectFit</span> <span class="p">=</span> <span class="kc">false</span>

<span class="c"># Hugo 解析文档的配置</span>
<span class="p">[</span><span class="nx">markup</span><span class="p">]</span>
  <span class="c"># <a href="https://gohugo.io/content-management/syntax-highlighting" target="_blank" rel="noopener noreffer">语法高亮设置</a></span>
  <span class="p">[</span><span class="nx">markup</span><span class="p">.</span><span class="nx">highlight</span><span class="p">]</span>
    <span class="nx">codeFences</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="nx">guessSyntax</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="nx">lineNos</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="nx">lineNumbersInTable</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="c"># false 是必要的设置</span>
    <span class="c"># (<a href="https://github.com/dillonzq/LoveIt/issues/158" target="_blank" rel="noopener noreffer">https://github.com/dillonzq/LoveIt/issues/158</a>)</span>
    <span class="nx">noClasses</span> <span class="p">=</span> <span class="kc">false</span>
  <span class="c"># Goldmark 是 Hugo 0.60 以来的默认 Markdown 解析库</span>
  <span class="p">[</span><span class="nx">markup</span><span class="p">.</span><span class="nx">goldmark</span><span class="p">]</span>
    <span class="p">[</span><span class="nx">markup</span><span class="p">.</span><span class="nx">goldmark</span><span class="p">.</span><span class="nx">extensions</span><span class="p">]</span>
      <span class="nx">definitionList</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">footnote</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">linkify</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">strikethrough</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">table</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">taskList</span> <span class="p">=</span> <span class="kc">true</span>
      <span class="nx">typographer</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="p">[</span><span class="nx">markup</span><span class="p">.</span><span class="nx">goldmark</span><span class="p">.</span><span class="nx">renderer</span><span class="p">]</span>
      <span class="c"># 是否在文档中直接使用 HTML 标签</span>
      <span class="nx">unsafe</span> <span class="p">=</span> <span class="kc">true</span>
  <span class="c"># 目录设置</span>
  <span class="p">[</span><span class="nx">markup</span><span class="p">.</span><span class="nx">tableOfContents</span><span class="p">]</span>
    <span class="nx">startLevel</span> <span class="p">=</span> <span class="mi">2</span>
    <span class="nx">endLevel</span> <span class="p">=</span> <span class="mi">6</span>

<span class="c"># 作者配置</span>
<span class="p">[</span><span class="nx">author</span><span class="p">]</span>
  <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;xxxx&#34;</span>
  <span class="nx">email</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
  <span class="nx">link</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>

<span class="c"># 网站地图配置</span>
<span class="p">[</span><span class="nx">sitemap</span><span class="p">]</span>
  <span class="nx">changefreq</span> <span class="p">=</span> <span class="s2">&#34;weekly&#34;</span>
  <span class="nx">filename</span> <span class="p">=</span> <span class="s2">&#34;sitemap.xml&#34;</span>
  <span class="nx">priority</span> <span class="p">=</span> <span class="mf">0.5</span>

<span class="c"># <a href="https://gohugo.io/content-management/urls#permalinks" target="_blank" rel="noopener noreffer">Permalinks 配置</a></span>
<span class="p">[</span><span class="nx">Permalinks</span><span class="p">]</span>
  <span class="c"># posts = &#34;:year/:month/:filename&#34;</span>
  <span class="nx">posts</span> <span class="p">=</span> <span class="s2">&#34;:filename&#34;</span>

<span class="c"># <a href="https://gohugo.io/about/hugo-and-gdpr/" target="_blank" rel="noopener noreffer">隐私信息配置</a></span>
<span class="p">[</span><span class="nx">privacy</span><span class="p">]</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-deleted.min.svg"
        data-srcset="/svg/version/0.2.0-deleted.min.svg, /svg/version/0.2.0-deleted.min.svg 1.5x, /svg/version/0.2.0-deleted.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 删除 | 0.2.0"
        title="LoveIt 删除 | 0.2.0" /></a> Google Analytics 相关隐私 (被 params.analytics.google 替代)</span>
  <span class="p">[</span><span class="nx">privacy</span><span class="p">.</span><span class="nx">googleAnalytics</span><span class="p">]</span>
    <span class="c"># ...</span>
  <span class="p">[</span><span class="nx">privacy</span><span class="p">.</span><span class="nx">twitter</span><span class="p">]</span>
    <span class="nx">enableDNT</span> <span class="p">=</span> <span class="kc">true</span>
  <span class="p">[</span><span class="nx">privacy</span><span class="p">.</span><span class="nx">youtube</span><span class="p">]</span>
    <span class="nx">privacyEnhanced</span> <span class="p">=</span> <span class="kc">true</span>

<span class="c"># 用于输出 Markdown 格式文档的设置</span>
<span class="p">[</span><span class="nx">mediaTypes</span><span class="p">]</span>
  <span class="p">[</span><span class="nx">mediaTypes</span><span class="p">.</span><span class="s2">&#34;text/plain&#34;</span><span class="p">]</span>
    <span class="nx">suffixes</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;md&#34;</span><span class="p">]</span>

<span class="c"># 用于输出 Markdown 格式文档的设置</span>
<span class="p">[</span><span class="nx">outputFormats</span><span class="p">.</span><span class="nx">MarkDown</span><span class="p">]</span>
  <span class="nx">mediaType</span> <span class="p">=</span> <span class="s2">&#34;text/plain&#34;</span>
  <span class="nx">isPlainText</span> <span class="p">=</span> <span class="kc">true</span>
  <span class="nx">isHTML</span> <span class="p">=</span> <span class="kc">false</span>

<span class="c"># 用于 Hugo 输出文档的设置</span>
<span class="p">[</span><span class="nx">outputs</span><span class="p">]</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-changed.min.svg"
        data-srcset="/svg/version/0.2.0-changed.min.svg, /svg/version/0.2.0-changed.min.svg 1.5x, /svg/version/0.2.0-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.0"
        title="LoveIt 更改 | 0.2.0" /></a></span>
  <span class="nx">home</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;HTML&#34;</span><span class="p">,</span> <span class="s2">&#34;RSS&#34;</span><span class="p">,</span> <span class="s2">&#34;JSON&#34;</span><span class="p">]</span>
  <span class="nx">page</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;HTML&#34;</span><span class="p">,</span> <span class="s2">&#34;MarkDown&#34;</span><span class="p">]</span>
  <span class="nx">section</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;HTML&#34;</span><span class="p">,</span> <span class="s2">&#34;RSS&#34;</span><span class="p">]</span>
  <span class="nx">taxonomy</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;HTML&#34;</span><span class="p">,</span> <span class="s2">&#34;RSS&#34;</span><span class="p">]</span>
  <span class="nx">taxonomyTerm</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;HTML&#34;</span><span class="p">]</span>
</code></pre></td></tr></table>
</div>
</div><div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>注意<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">请注意, 本文档其他部分将详细解释其中一些参数.</div>
        </div>
    </div>
<div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>Hugo 的运行环境<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content"><p><code>hugo serve</code> 的默认运行环境是 <code>development</code>,
而 <code>hugo</code> 的默认运行环境是 <code>production</code>.</p>
<p>由于本地 <code>development</code> 环境的限制,
<strong>评论系统</strong>, <strong>CDN</strong> 和 <strong>fingerprint</strong> 不会在 <code>development</code> 环境下启用.</p>
<p>你可以使用 <code>hugo serve -e production</code> 命令来开启这些特性.</p>
</div>
        </div>
    </div>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>关于 CDN 配置的技巧<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content"><p><a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.7" rel="noopener noreffer" target="_blank"><img
class="lazyload version"
src="/svg/loading.min.svg"
data-src="/svg/version/0.2.7-changed.min.svg"
data-srcset="/svg/version/0.2.7-changed.min.svg, /svg/version/0.2.7-changed.min.svg 1.5x, /svg/version/0.2.7-changed.min.svg 2x"
data-sizes="auto"
alt="LoveIt 更改 | 0.2.7"
title="LoveIt 更改 | 0.2.7" /></a></p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span><span class="lnt">3
</span><span class="lnt">4
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">cdn</span><span class="p">]</span>
  <span class="c"># CDN 数据文件名称, 默认不启用</span>
  <span class="c"># (&#34;jsdelivr.yml&#34;)</span>
  <span class="nx">data</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</code></pre></td></tr></table>
</div>
</div><p>默认的 CDN 数据文件位于 <code>themes/LoveIt/assets/data/cdn/</code> 目录.
可以在你的项目下相同路径存放你自己的数据文件: <code>assets/data/cdn/</code>.</p>
</div>
        </div>
    </div>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>关于社交链接配置的技巧<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content"><p><a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
class="lazyload version"
src="/svg/loading.min.svg"
data-src="/svg/version/0.2.0-new.min.svg"
data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
data-sizes="auto"
alt="LoveIt 新增 | 0.2.0"
title="LoveIt 新增 | 0.2.0" /></a></p>
<p>你可以直接配置你的社交 ID 来生成一个默认社交链接和图标:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">social</span><span class="p">]</span>
  <span class="nx">Mastodon</span> <span class="p">=</span> <span class="s2">&#34;@xxxx&#34;</span>
</code></pre></td></tr></table>
</div>
</div><p>生成的社交链接是 <code>https://mastodon.technology/@xxxx</code>.</p>
<p>或者你可以通过一个字典来设置更多的选项:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt"> 1
</span><span class="lnt"> 2
</span><span class="lnt"> 3
</span><span class="lnt"> 4
</span><span class="lnt"> 5
</span><span class="lnt"> 6
</span><span class="lnt"> 7
</span><span class="lnt"> 8
</span><span class="lnt"> 9
</span><span class="lnt">10
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">social</span><span class="p">]</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">social</span><span class="p">.</span><span class="nx">Mastodon</span><span class="p">]</span>
    <span class="c"># 排列图标时的权重 (权重越大, 图标的位置越靠后)</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">0</span>
    <span class="c"># 你的社交 ID</span>
    <span class="nx">id</span> <span class="p">=</span> <span class="s2">&#34;@xxxx&#34;</span>
    <span class="c"># 你的社交链接的前缀</span>
    <span class="nx">prefix</span> <span class="p">=</span> <span class="s2">&#34;https://mastodon.social/&#34;</span>
    <span class="c"># 当鼠标停留在图标上时的提示内容</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;Mastodon&#34;</span>
</code></pre></td></tr></table>
</div>
</div><p>所有支持的社交链接的默认数据位于 <code>themes/LoveIt/assets/data/social.yaml</code>.
你可以参考它来配置你的社交链接.</p>
</div>
        </div>
    </div>
<p><figure><a class="lightgallery" href="/posts/theme-documentation-basics/complete-configuration-preview.zh-cn.png" title="完整配置下的预览" data-thumbnail="/posts/theme-documentation-basics/complete-configuration-preview.zh-cn.png" data-sub-html="<h2>完整配置下的预览</h2><p>完整配置下的预览</p>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="complete-configuration-preview.zh-cn.png"
            data-srcset="/posts/theme-documentation-basics/complete-configuration-preview.zh-cn.png, complete-configuration-preview.zh-cn.png 1.5x, /posts/theme-documentation-basics/complete-configuration-preview.zh-cn.png 2x"
            data-sizes="auto"
            alt="/posts/theme-documentation-basics/complete-configuration-preview.zh-cn.png" />
    </a><figcaption class="image-caption">完整配置下的预览</figcaption>
    </figure></p>
<h3 id="32-网站图标-浏览器配置-网站清单">3.2 网站图标, 浏览器配置, 网站清单</h3>
<p>强烈建议你把:</p>
<ul>
<li>apple-touch-icon.png (180x180)</li>
<li>favicon-32x32.png (32x32)</li>
<li>favicon-16x16.png (16x16)</li>
<li>mstile-150x150.png (150x150)</li>
<li>android-chrome-192x192.png (192x192)</li>
<li>android-chrome-512x512.png (512x512)</li>
</ul>
<p>放在 <code>/static</code> 目录. 利用 <a href="https://realfavicongenerator.net/" target="_blank" rel="noopener noreffer">https://realfavicongenerator.net/</a> 可以很容易地生成这些文件.</p>
<p>可以自定义 <code>browserconfig.xml</code> 和 <code>site.webmanifest</code> 文件来设置 theme-color 和 background-color.</p>
<h3 id="33-自定义样式">3.3 自定义样式</h3>
<a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.8" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.8-changed.min.svg"
        data-srcset="/svg/version/0.2.8-changed.min.svg, /svg/version/0.2.8-changed.min.svg 1.5x, /svg/version/0.2.8-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.8"
        title="LoveIt 更改 | 0.2.8" /></a>
<div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>注意<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">Hugo <strong>extended</strong> 版本对于自定义样式是必需的.</div>
        </div>
    </div>
<p>通过定义自定义 <code>.scss</code> 样式文件, <strong>LoveIt</strong> 主题支持可配置的样式.</p>
<p>包含自定义 <code>.scss</code> 样式文件的目录相对于 <strong>你的项目根目录</strong> 的路径为 <code>assets/css</code>.</p>
<p>在 <code>assets/css/_override.scss</code> 中, 你可以覆盖 <code>themes/LoveIt/assets/css/_variables.scss</code> 中的变量以自定义样式.</p>
<p>这是一个例子:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-scss" data-lang="scss"><span class="k">@import</span> <span class="sx">url(&#39;https://fonts.googleapis.com/css?family=Fira+Mono:400,700&amp;display=swap&amp;subset=latin-ext&#39;)</span><span class="p">;</span>
<span class="nv">$code-font-family</span><span class="o">:</span> <span class="n">Fira</span> <span class="n">Mono</span><span class="o">,</span> <span class="n">Source</span> <span class="n">Code</span> <span class="n">Pro</span><span class="o">,</span> <span class="n">Menlo</span><span class="o">,</span> <span class="n">Consolas</span><span class="o">,</span> <span class="n">Monaco</span><span class="o">,</span> <span class="no">monospace</span><span class="p">;</span>
</code></pre></td></tr></table>
</div>
</div><p>在 <code>assets/css/_custom.scss</code> 中, 你可以添加一些 CSS 样式代码以自定义样式.</p>
<h2 id="4-多语言和-i18n">4 多语言和 i18n</h2>
<p><strong>LoveIt</strong> 主题完全兼容 Hugo 的多语言模式, 并且支持在网页上切换语言.</p>
<p><figure><a class="lightgallery" href="/posts/theme-documentation-basics/language-switch.gif" title="语言切换" data-thumbnail="/posts/theme-documentation-basics/language-switch.gif" data-sub-html="<h2>语言切换</h2><p>语言切换</p>">
        <img
            class="lazyload"
            src="/svg/loading.min.svg"
            data-src="language-switch.gif"
            data-srcset="/posts/theme-documentation-basics/language-switch.gif, language-switch.gif 1.5x, /posts/theme-documentation-basics/language-switch.gif 2x"
            data-sizes="auto"
            alt="/posts/theme-documentation-basics/language-switch.gif" />
    </a><figcaption class="image-caption">语言切换</figcaption>
    </figure></p>
<h3 id="language-compatibility">4.1 兼容性</h3>
<a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.10" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.10-changed.min.svg"
        data-srcset="/svg/version/0.2.10-changed.min.svg, /svg/version/0.2.10-changed.min.svg 1.5x, /svg/version/0.2.10-changed.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 更改 | 0.2.10"
        title="LoveIt 更改 | 0.2.10" /></a>
<table>
<thead>
<tr>
<th style="text-align:left">语言</th>
<th style="text-align:center">Hugo 代码</th>
<th style="text-align:center">HTML <code>lang</code> 属性</th>
<th style="text-align:center">主题文档</th>
<th style="text-align:center">Lunr.js 支持</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align:left">英语</td>
<td style="text-align:center"><code>en</code></td>
<td style="text-align:center"><code>en</code></td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">简体中文</td>
<td style="text-align:center"><code>zh-cn</code></td>
<td style="text-align:center"><code>zh-CN</code></td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">法语</td>
<td style="text-align:center"><code>fr</code></td>
<td style="text-align:center"><code>fr</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">波兰语</td>
<td style="text-align:center"><code>pl</code></td>
<td style="text-align:center"><code>pl</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">巴西葡萄牙语</td>
<td style="text-align:center"><code>pt-br</code></td>
<td style="text-align:center"><code>pt-BR</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">意大利语</td>
<td style="text-align:center"><code>it</code></td>
<td style="text-align:center"><code>it</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">西班牙语</td>
<td style="text-align:center"><code>es</code></td>
<td style="text-align:center"><code>es</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">德语</td>
<td style="text-align:center"><code>de</code></td>
<td style="text-align:center"><code>de</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">塞尔维亚语</td>
<td style="text-align:center"><code>pl</code></td>
<td style="text-align:center"><code>pl</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">俄语</td>
<td style="text-align:center"><code>ru</code></td>
<td style="text-align:center"><code>ru</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">罗马尼亚语</td>
<td style="text-align:center"><code>ro</code></td>
<td style="text-align:center"><code>ro</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
<tr>
<td style="text-align:left">越南语</td>
<td style="text-align:center"><code>vi</code></td>
<td style="text-align:center"><code>vi</code></td>
<td style="text-align:center">:(far fa-square fa-fw):</td>
<td style="text-align:center">:(far fa-check-square fa-fw):</td>
</tr>
</tbody>
</table>
<h3 id="42-基本配置">4.2 基本配置</h3>
<p>学习了 <a href="https://gohugo.io/content-management/multilingual" target="_blank" rel="noopener noreffer">Hugo如何处理多语言网站</a> 之后, 请在 <a href="#site-configuration" rel="">站点配置</a> 中定义你的网站语言.</p>
<p>例如, 一个支持英语, 中文和法语的网站配置:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt"> 1
</span><span class="lnt"> 2
</span><span class="lnt"> 3
</span><span class="lnt"> 4
</span><span class="lnt"> 5
</span><span class="lnt"> 6
</span><span class="lnt"> 7
</span><span class="lnt"> 8
</span><span class="lnt"> 9
</span><span class="lnt">10
</span><span class="lnt">11
</span><span class="lnt">12
</span><span class="lnt">13
</span><span class="lnt">14
</span><span class="lnt">15
</span><span class="lnt">16
</span><span class="lnt">17
</span><span class="lnt">18
</span><span class="lnt">19
</span><span class="lnt">20
</span><span class="lnt">21
</span><span class="lnt">22
</span><span class="lnt">23
</span><span class="lnt">24
</span><span class="lnt">25
</span><span class="lnt">26
</span><span class="lnt">27
</span><span class="lnt">28
</span><span class="lnt">29
</span><span class="lnt">30
</span><span class="lnt">31
</span><span class="lnt">32
</span><span class="lnt">33
</span><span class="lnt">34
</span><span class="lnt">35
</span><span class="lnt">36
</span><span class="lnt">37
</span><span class="lnt">38
</span><span class="lnt">39
</span><span class="lnt">40
</span><span class="lnt">41
</span><span class="lnt">42
</span><span class="lnt">43
</span><span class="lnt">44
</span><span class="lnt">45
</span><span class="lnt">46
</span><span class="lnt">47
</span><span class="lnt">48
</span><span class="lnt">49
</span><span class="lnt">50
</span><span class="lnt">51
</span><span class="lnt">52
</span><span class="lnt">53
</span><span class="lnt">54
</span><span class="lnt">55
</span><span class="lnt">56
</span><span class="lnt">57
</span><span class="lnt">58
</span><span class="lnt">59
</span><span class="lnt">60
</span><span class="lnt">61
</span><span class="lnt">62
</span><span class="lnt">63
</span><span class="lnt">64
</span><span class="lnt">65
</span><span class="lnt">66
</span><span class="lnt">67
</span><span class="lnt">68
</span><span class="lnt">69
</span><span class="lnt">70
</span><span class="lnt">71
</span><span class="lnt">72
</span><span class="lnt">73
</span><span class="lnt">74
</span><span class="lnt">75
</span><span class="lnt">76
</span><span class="lnt">77
</span><span class="lnt">78
</span><span class="lnt">79
</span><span class="lnt">80
</span><span class="lnt">81
</span><span class="lnt">82
</span><span class="lnt">83
</span><span class="lnt">84
</span><span class="lnt">85
</span><span class="lnt">86
</span><span class="lnt">87
</span><span class="lnt">88
</span><span class="lnt">89
</span><span class="lnt">90
</span><span class="lnt">91
</span><span class="lnt">92
</span><span class="lnt">93
</span><span class="lnt">94
</span><span class="lnt">95
</span><span class="lnt">96
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="c"># [en, zh-cn, fr, pl, ...] 设置默认的语言</span>
<span class="nx">defaultContentLanguage</span> <span class="p">=</span> <span class="s2">&#34;zh-cn&#34;</span>

<span class="p">[</span><span class="nx">languages</span><span class="p">]</span>
  <span class="p">[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">en</span><span class="p">]</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">1</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;My New Hugo Site&#34;</span>
    <span class="nx">languageCode</span> <span class="p">=</span> <span class="s2">&#34;en&#34;</span>
    <span class="nx">languageName</span> <span class="p">=</span> <span class="s2">&#34;English&#34;</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">en</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;posts&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;Posts&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/posts/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">1</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">en</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;tags&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;Tags&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/tags/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">2</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">en</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;categories&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;Categories&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/categories/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">3</span>

  <span class="p">[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">zh</span><span class="err">-</span><span class="nx">cn</span><span class="p">]</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">2</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;我的全新 Hugo 网站&#34;</span>
    <span class="c"># 网站语言, 仅在这里 CN 大写</span>
    <span class="nx">languageCode</span> <span class="p">=</span> <span class="s2">&#34;zh-CN&#34;</span>
    <span class="nx">languageName</span> <span class="p">=</span> <span class="s2">&#34;简体中文&#34;</span>
    <span class="c"># 是否包括中日韩文字</span>
    <span class="nx">hasCJKLanguage</span> <span class="p">=</span> <span class="kc">true</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">zh</span><span class="err">-</span><span class="nx">cn</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;posts&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;文章&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/posts/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">1</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">zh</span><span class="err">-</span><span class="nx">cn</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;tags&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;标签&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/tags/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">2</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">zh</span><span class="err">-</span><span class="nx">cn</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;categories&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;分类&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/categories/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">3</span>

  <span class="p">[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">fr</span><span class="p">]</span>
    <span class="nx">weight</span> <span class="p">=</span> <span class="mi">3</span>
    <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;Mon nouveau site Hugo&#34;</span>
    <span class="nx">languageCode</span> <span class="p">=</span> <span class="s2">&#34;fr&#34;</span>
    <span class="nx">languageName</span> <span class="p">=</span> <span class="s2">&#34;Français&#34;</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">fr</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;posts&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;Postes&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/posts/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">1</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">fr</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;tags&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;Balises&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/tags/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">2</span>
    <span class="p">[[</span><span class="nx">languages</span><span class="p">.</span><span class="nx">fr</span><span class="p">.</span><span class="nx">menu</span><span class="p">.</span><span class="nx">main</span><span class="p">]]</span>
      <span class="nx">identifier</span> <span class="p">=</span> <span class="s2">&#34;categories&#34;</span>
      <span class="nx">pre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">post</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">name</span> <span class="p">=</span> <span class="s2">&#34;Catégories&#34;</span>
      <span class="nx">url</span> <span class="p">=</span> <span class="s2">&#34;/categories/&#34;</span>
      <span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
      <span class="nx">weight</span> <span class="p">=</span> <span class="mi">3</span>
</code></pre></td></tr></table>
</div>
</div><p>然后, 对于每个新页面, 将语言代码附加到文件名中.</p>
<p>单个文件 <code>my-page.md</code> 需要分为三个文件:</p>
<ul>
<li>英语: <code>my-page.en.md</code></li>
<li>中文: <code>my-page.zh-cn.md</code></li>
<li>法语: <code>my-page.fr.md</code></li>
</ul>
<div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>注意<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">请注意, 菜单中仅显示翻译的页面. 它不会替换为默认语言内容.</div>
        </div>
    </div>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>技巧<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">也可以使用 <a href="https://gohugo.io/content-management/multilingual#translate-your-content" target="_blank" rel="noopener noreffer">文章前置参数</a> 来翻译网址.</div>
        </div>
    </div>
<h3 id="43-修改默认的翻译字符串">4.3 修改默认的翻译字符串</h3>
<p>翻译字符串用于在主题中使用的常见默认值.
目前提供<a href="#language-compatibility" rel="">一些语言</a>的翻译, 但你可能自定义其他语言或覆盖默认值.</p>
<p>要覆盖默认值, 请在你项目的 i18n 目录 <code>i18n/&lt;languageCode&gt;.toml</code> 中创建一个新文件，并从 <code>themes/LoveIt/i18n/en.toml</code> 中获得提示.</p>
<p>另外, 由于你的翻译可能会帮助到其他人, 请花点时间通过 <a href="https://github.com/dillonzq/LoveIt/pulls" target="_blank" rel="noopener noreffer">:(fas fa-code-branch fa-fw): 创建一个 PR</a> 来贡献主题翻译, 谢谢!</p>
<h2 id="5-搜索">5 搜索</h2>
<a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.0" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.0-new.min.svg"
        data-srcset="/svg/version/0.2.0-new.min.svg, /svg/version/0.2.0-new.min.svg 1.5x, /svg/version/0.2.0-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.0"
        title="LoveIt 新增 | 0.2.0" /></a>
<p>基于 <a href="https://lunrjs.com/" target="_blank" rel="noopener noreffer">Lunr.js</a> 或 <a href="https://www.algolia.com/" target="_blank" rel="noopener noreffer">algolia</a>, <strong>LoveIt</strong> 主题支持搜索功能.</p>
<h3 id="51-输出配置">5.1 输出配置</h3>
<p>为了生成搜索功能所需要的 <code>index.json</code>, 请在你的 <a href="#site-configuration" rel="">网站配置</a> 中添加 <code>JSON</code> 输出文件类型到 <code>outputs</code> 部分的 <code>home</code> 字段中.</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt">1
</span><span class="lnt">2
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="p">[</span><span class="nx">outputs</span><span class="p">]</span>
  <span class="nx">home</span> <span class="p">=</span> <span class="p">[</span><span class="s2">&#34;HTML&#34;</span><span class="p">,</span> <span class="s2">&#34;RSS&#34;</span><span class="p">,</span> <span class="s2">&#34;JSON&#34;</span><span class="p">]</span>
</code></pre></td></tr></table>
</div>
</div><h3 id="52-搜索配置">5.2 搜索配置</h3>
<p>基于 Hugo 生成的 <code>index.json</code> 文件, 你可以激活搜索功能.</p>
<p>这是你的 <a href="#site-configuration" rel="">网站配置</a> 中的搜索部分:</p>
<div class="highlight"><div class="chroma">
<table class="lntable"><tr><td class="lntd">
<pre class="chroma"><code><span class="lnt"> 1
</span><span class="lnt"> 2
</span><span class="lnt"> 3
</span><span class="lnt"> 4
</span><span class="lnt"> 5
</span><span class="lnt"> 6
</span><span class="lnt"> 7
</span><span class="lnt"> 8
</span><span class="lnt"> 9
</span><span class="lnt">10
</span><span class="lnt">11
</span><span class="lnt">12
</span><span class="lnt">13
</span><span class="lnt">14
</span><span class="lnt">15
</span><span class="lnt">16
</span><span class="lnt">17
</span><span class="lnt">18
</span><span class="lnt">19
</span><span class="lnt">20
</span></code></pre></td>
<td class="lntd">
<pre class="chroma"><code class="language-toml" data-lang="toml"><span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">search</span><span class="p">]</span>
  <span class="nx">enable</span> <span class="p">=</span> <span class="kc">true</span>
  <span class="c"># 搜索引擎的类型 (&#34;lunr&#34;, &#34;algolia&#34;)</span>
  <span class="nx">type</span> <span class="p">=</span> <span class="s2">&#34;lunr&#34;</span>
  <span class="c"># 文章内容最长索引长度</span>
  <span class="nx">contentLength</span> <span class="p">=</span> <span class="mi">4000</span>
  <span class="c"># 搜索框的占位提示语</span>
  <span class="nx">placeholder</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.1-new.min.svg"
        data-srcset="/svg/version/0.2.1-new.min.svg, /svg/version/0.2.1-new.min.svg 1.5x, /svg/version/0.2.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.1"
        title="LoveIt 新增 | 0.2.1" /></a> 最大结果数目</span>
  <span class="nx">maxResultLength</span> <span class="p">=</span> <span class="mi">10</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.3" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.3-new.min.svg"
        data-srcset="/svg/version/0.2.3-new.min.svg, /svg/version/0.2.3-new.min.svg 1.5x, /svg/version/0.2.3-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.3"
        title="LoveIt 新增 | 0.2.3" /></a> 结果内容片段长度</span>
  <span class="nx">snippetLength</span> <span class="p">=</span> <span class="mi">50</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.1" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.1-new.min.svg"
        data-srcset="/svg/version/0.2.1-new.min.svg, /svg/version/0.2.1-new.min.svg 1.5x, /svg/version/0.2.1-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.1"
        title="LoveIt 新增 | 0.2.1" /></a> 搜索结果中高亮部分的 HTML 标签</span>
  <span class="nx">highlightTag</span> <span class="p">=</span> <span class="s2">&#34;em&#34;</span>
  <span class="c"># <a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.4" rel="noopener noreffer" target="_blank"><img
        class="lazyload version"
        src="/svg/loading.min.svg"
        data-src="/svg/version/0.2.4-new.min.svg"
        data-srcset="/svg/version/0.2.4-new.min.svg, /svg/version/0.2.4-new.min.svg 1.5x, /svg/version/0.2.4-new.min.svg 2x"
        data-sizes="auto"
        alt="LoveIt 新增 | 0.2.4"
        title="LoveIt 新增 | 0.2.4" /></a> 是否在搜索索引中使用基于 baseURL 的绝对路径</span>
  <span class="nx">absoluteURL</span> <span class="p">=</span> <span class="kc">false</span>
  <span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">search</span><span class="p">.</span><span class="nx">algolia</span><span class="p">]</span>
    <span class="nx">index</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">appID</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
    <span class="nx">searchKey</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</code></pre></td></tr></table>
</div>
</div><div class="details admonition note open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-pencil-alt fa-fw"></i>怎样选择搜索引擎?<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content"><p>以下是两种搜索引擎的对比:</p>
<ul>
<li><code>lunr</code>: 简单, 无需同步 <code>index.json</code>, 没有 <code>contentLength</code> 的限制, 但占用带宽大且性能低 (特别是中文需要一个较大的分词依赖库)</li>
<li><code>algolia</code>: 高性能并且占用带宽低, 但需要同步 <code>index.json</code> 且有 <code>contentLength</code> 的限制</li>
</ul>
<p><a href="https://github.com/dillonzq/LoveIt/releases/tag/v0.2.3" rel="noopener noreffer" target="_blank"><img
class="lazyload version"
src="/svg/loading.min.svg"
data-src="/svg/version/0.2.3-new.min.svg"
data-srcset="/svg/version/0.2.3-new.min.svg, /svg/version/0.2.3-new.min.svg 1.5x, /svg/version/0.2.3-new.min.svg 2x"
data-sizes="auto"
alt="LoveIt 新增 | 0.2.3"
title="LoveIt 新增 | 0.2.3" /></a> 文章内容被 <code>h2</code> 和 <code>h3</code> HTML 标签切分来提高查询效果并且基本实现全文搜索.
<code>contentLength</code> 用来限制 <code>h2</code> 和 <code>h3</code> HTML 标签开头的内容部分的最大长度.</p>
</div>
        </div>
    </div>
<div class="details admonition tip open">
        <div class="details-summary admonition-title">
            <i class="icon fas fa-lightbulb fa-fw"></i>关于 algolia 的使用技巧<i class="details-icon fas fa-angle-right fa-fw"></i>
        </div>
        <div class="details-content">
            <div class="admonition-content">你需要上传 <code>index.json</code> 到 algolia 来激活搜索功能. 你可以使用浏览器来上传 <code>index.json</code> 文件但是一个自动化的脚本可能效果更好.
<a href="https://github.com/chrisdmacrae/atomic-algolia" target="_blank" rel="noopener noreffer">Algolia Atomic</a> 是一个不错的选择.
为了兼容 Hugo 的多语言模式, 你需要上传不同语言的 <code>index.json</code> 文件到对应的 algolia index, 例如 <code>zh-cn/index.json</code> 或 <code>fr/index.json</code>&hellip;</div>
        </div>
    </div></div><div class="post-footer" id="post-footer">
    <div class="post-info">
        <div class="post-info-line">
            <div class="post-info-mod">
                <span>更新于 2020-03-06</span>
            </div>
            <div class="post-info-license"></div>
        </div>
        <div class="post-info-line">
            <div class="post-info-md"></div>
            <div class="post-info-share">
                <span></span>
            </div>
        </div>
    </div>

    <div class="post-info-more">
        <section class="post-tags"><i class="fas fa-tags fa-fw"></i>&nbsp;<a href="/tags/installation/">安装</a>,&nbsp;<a href="/tags/configuration/">配置</a></section>
        <section>
            <span><a href="javascript:void(0);" onclick="window.history.back();">返回</a></span>&nbsp;|&nbsp;<span><a href="/">主页</a></span>
        </section>
    </div>

    <div class="post-nav"><a href="/posts/theme-documentation-content/" class="prev" rel="prev" title="主题文档 - 内容"><i class="fas fa-angle-left fa-fw"></i>主题文档 - 内容</a></div>
</div>
</article></div>
            </main><footer class="footer">
        <div class="footer-container"><div class="footer-line">由 <a href="https://gohugo.io/" target="_blank" rel="noopener noreffer" title="Hugo 0.79.1">Hugo</a> 强力驱动 | 主题 - <a href="https://github.com/dillonzq/LoveIt" target="_blank" rel="noopener noreffer" title="LoveIt 0.2.10"><i class="far fa-kiss-wink-heart fa-fw"></i> LoveIt</a>
                </div><div class="footer-line"><i class="far fa-copyright fa-fw"></i><span itemprop="copyrightYear">2021</span><span class="author" itemprop="copyrightHolder">&nbsp;<a href="/" target="_blank">Luckly</a></span></div>
        </div>
    </footer></div>

        <div id="fixed-buttons"><a href="#" id="back-to-top" class="fixed-button" title="回到顶部">
                <i class="fas fa-arrow-up fa-fw"></i>
            </a><a href="#" id="view-comments" class="fixed-button" title="查看评论">
                <i class="fas fa-comment fa-fw"></i>
            </a>
        </div><link rel="stylesheet" href="/lib/lightgallery/lightgallery.min.css"><script type="text/javascript" src="/lib/smooth-scroll/smooth-scroll.min.js"></script><script type="text/javascript" src="/lib/lazysizes/lazysizes.min.js"></script><script type="text/javascript" src="/lib/lightgallery/lightgallery.min.js"></script><script type="text/javascript" src="/lib/lightgallery/lg-thumbnail.min.js"></script><script type="text/javascript" src="/lib/lightgallery/lg-zoom.min.js"></script><script type="text/javascript" src="/lib/clipboard/clipboard.min.js"></script><script type="text/javascript">window.config={"code":{"copyTitle":"复制到剪贴板","maxShownLines":10},"comment":{},"lightGallery":{"actualSize":false,"exThumbImage":"data-thumbnail","hideBarsDelay":2000,"selector":".lightgallery","speed":400,"thumbContHeight":80,"thumbWidth":80,"thumbnail":true}};</script><script type="text/javascript" src="/js/theme.min.js"></script></body>
</html>
